//
//  ViewController.m
//  10505、颜色生成
//
//  Created by student on 16/2/19.
//  Copyright © 2016年 niit. All rights reserved.
//

#import "ViewController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (IBAction)SliderChanged:(UISlider *)sender {
//    float value=sender.value;
    
    self.label1.text=[NSString stringWithFormat:@"%.2f",self.sliderred.value];
    self.label2.text=[NSString stringWithFormat:@"%f.2",self.slidergreen.value];
    self.label3.text=[NSString stringWithFormat:@"%f.2",self.sliderblue.value];
    
    self.viewChanged.backgroundColor=[UIColor colorWithRed:self.sliderred.value green:self.slidergreen.value blue:self.sliderblue.value alpha:1];
    
}




@end
